#include <QCoreApplication>
#include <iostream>
using namespace std;

int main()
{
    int k=456;
    int l=k%10*100+k/10%10*10+k/100;
    cout<<l<<endl;
    return 0;
}
